from apscheduler.schedulers.background import BackgroundScheduler
from flask_pymongo import PyMongo
from flask_celery import Celery
from flask_socketio import SocketIO
from flask_apscheduler import APScheduler

# MC = MongoClient('127.0.0.1', 27017)
# MongoDB = MC['log']  # 创建数据库（内存中）


mongo = PyMongo()
# celery -A manger.celery worker -l info --pool=solo -f logs/celery.log
celery = Celery()

socket_io = SocketIO()

# 集成flask_apscheduler
scheduler = APScheduler(BackgroundScheduler(timezone='Asia/Shanghai'))
